/**
 * HW8
 *
 * brief description of the program
 *
 * This program is released to public domain according to
 * author's wish, you can view full license at
 * http://tomatoeskit.org/upload/PublicDomainLicense.txt
 *
 * @author Fangning CHENG (Alpha.L Cheng) <chengf@purdue.edu>
 *
 * @lab section number 
 *
 * @date Sep 9, 2013
 *
 */

import java.util.Scanner;

public class Calculator {
    public static int sum(String s)
    {
        Scanner scanner = new Scanner(s);
        int ret = 0;
        while(scanner.hasNextInt()) {
            ret += scanner.nextInt();
        }
        scanner.close();
        return ret;
    }

}
